home *** CD-ROM | disk | FTP | other *** search
- Attribute VB_Name = "Globals"
- Option Explicit
- Public Function GetTrackFileErrorMessage(ByVal FileError As CDRPROXLibCtl.eTrackFileError, ByVal FileName As String)
- Dim strErrorMsg As String
-
- 'This function will handle a track file error
- Select Case FileError
- Case tfeFileOpenError
- strErrorMsg = "Error Opening File: " & FileName
- Case tfeFileCloseError
- strErrorMsg = "Error Closing File: " & FileName
- Case tfeFileReadError
- strErrorMsg = "Error Reading file: " & FileName
- Case Else
- strErrorMsg = "Unknown file error!:" & FileName
- End Select
-
- 'Return error message
- GetTrackFileErrorMessage = strErrorMsg
- End Function
-
- Public Function GetDriveErrorMessage(ByVal DriveError As CDRPROXLibCtl.eCDError)
-
- Dim strMsg As String
-
- 'Get a String which explains the error code as explained in the help files
- Select Case DriveError
- Case cdNoAdditionalErrorData '1000
- strMsg = "No additional error data was reported"
- Case cdIOTerminated '1001
- strMsg = "Abnormal I/O Termination"
- Case cdLogicalUnitNotReady '1002
- strMsg = "The drive is not ready"
- Case cdLogicalUnitCommFailed '1003
- strMsg = "Communication with drive unit failed"
- Case cdDeviceTrackingError '1004
- strMsg = "The drive could not track properly"
- Case cdWriteGenericError '1005
- strMsg = "Writing error of unknown origin"
- Case cdWriteRecoveryNeeded '1006
- strMsg = "Writing occurred, but recovery is needed"
- Case cdWriteRecoveryFailed '1007
- strMsg = "Recovery attempt failed"
- Case cdWriteLossOfStreaming '1008
- strMsg = "A buffer under-run has occurred"
- Case cdReadUnrecovered '1009
- strMsg = "The disc could not be read"
- Case cdReadRetriesExhausted '1010
- strMsg = "The drive's attempts at reading retries failed"
- Case cdReadErrorTooLong '1011
- strMsg = "The read timed out"
- Case cdReadLECUncorrectable '1012
- strMsg = "While reading, the LEC was not recovered"
- Case cdReadCIRCUnrecovered '1013
- strMsg = "The CIRC could not be validated"
- Case cdReadUPCEANFailed '1014
- strMsg = "Reading of the UPC failed"
- Case cdReadISRCFailed '1015
- strMsg = "Reading of the ISRC failed"
- Case cdReadLossOfStreaming '1016
- strMsg = "Streaming while reading was interrupted"
- Case cdPositioningError '1017
- strMsg = "Drive could not position media"
- Case cdParameterListLengthError '1018
- strMsg = "An incompatible parameter length was sent to the drive"
- Case cdSynchronousTransferError '1019
- strMsg = "A transfer error occurred to the drive"
- Case cdInvalidCommandCode '1020
- strMsg = "An invalid command was sent to the drive"
- Case cdLBAOutOfRange '1021
- strMsg = "Error trying to write past the end of the media"
- Case cdInvalidCDBField '1022
- strMsg = "Invalid command field"
- Case cdInvalidParamterListField '1023
- strMsg = "An incompatible parameter field was sent to the drive"
- Case cdParameterNotSupported '1024
- strMsg = "A command parameter is not supported"
- Case cdParamterValueInvalid '1025
- strMsg = "A command parameter had an invalid value"
- Case cdBusOrDeviceReset '1026
- strMsg = "The SCSI/ATAPI bus was reset and caused a write failure"
- Case cdParametersChanged '1027
- strMsg = "A command parameter changed while in progress"
- Case cdIncompatibleMedium '1028
- strMsg = "The disc is not compatible with the drive mode"
- Case cdReadUnknownMediumFormat '1029
- strMsg = "The drive does not recognize the format of the disc"
- Case cdReadIncompatibleMediumFormat '1030
- strMsg = "The disc format is not compatible with the drive"
- Case cdWriteUnknownMediumFormat '1031
- strMsg = "The disc is of an unknown format"
- Case cdIncompatibleWriteFormat '1032
- strMsg = "The drive cannot write because of an incompatible format"
- Case cdMediaNotPresent '1033
- strMsg = "A disc is not present"
- Case cdLogicalUnitFailure '1034
- strMsg = "The drive had an unknown failure"
- Case cdLogicalUnitTimedOut '1035
- strMsg = "The drive has timed out while completing a command"
- Case cdEraseFailed '1036
- strMsg = "The disc could not be erased"
- Case cdUnableToRecoverTOC '1037
- strMsg = "The Table of Contents is unrecoverable"
- Case cdEndOfUserAreaOnTrack '1038
- strMsg = "Error trying to write past the user area of the media"
- Case cdPacketDoesNotFit '1039
- strMsg = "Packet recording is not configured correctly"
- Case cdIllegalTrackMode '1040
- strMsg = "The current track mode is incompatible with the disc format"
- Case cdInvalidPacketSize '1041
- strMsg = "Packet recording has incorrect size"
- Case cdSessionFixationError '1042
- strMsg = "A generic session closing error occurred"
- Case cdSessionFixationErrorLeadIn '1043
- strMsg = "Error closing Lead-in area"
- Case cdSessionFixationErrorLeadOut '1044
- strMsg = "Error closing Lead-out area"
- Case cdSessionFixationIncompleteTrack '1045
- strMsg = "While closing, the track was never completed"
- Case cdEmptyPartialReservedTrack '1046
- strMsg = "Error attempting to write to a reserved track"
- Case cdPowerCalibrationFull '1047
- strMsg = "Power calibration area is full"
- Case cdPowerCalibrationAreaError '1048
- strMsg = "A flaw exists in the Power calibration area"
- Case cdPMAUpdateFailure '1049
- strMsg = "The disc's PMA could not be updated"
- Case cdPMAFull '1050
- strMsg = "The disc's PMA is full"
- Case cdUnknownError '1051
- strMsg = "Unknown error - use extended data for more information"
- Case cdNoError '1052 - You will never see this most likely
- strMsg = "No Error Reported"
- Case cdNoSeekComplete '1053
- strMsg = "A seek command was interrupted by another command"
- Case cdNTIOError '1054
- strMsg = "A NT disc I/O operation failed"
- Case cdFormatInProgress '1055
- strMsg = "A format is in progress causing operation failure"
- End Select
-
- 'return the error string
- strMsg = strMsg & " (" & CStr(DriveError) & ")."
-
- GetDriveErrorMessage = strMsg
-
- End Function
-
-